<?php

namespace App\Http\Requests;

use Illuminate\Foundation\Http\FormRequest;

class NoticeRequest extends BaseFormRequest
{

    /**
     * Get the validation rules that apply to the request.
     *
     * @return array
     */
    public function rules()
    {

        return [
            'title'=>'required|string',
            'content'=>'required|string'
        ];
    }

    public function messages()
    {
        return [
            'title.required'=>'标题不能为空',
            'content.required'=>'内容不能为空',
        ];
    }
}
